package com.smartstate.EnvironmentMonitor.service;

import com.smartstate.EnvironmentMonitor.dto.ObjMoudelDTO;
import com.smartstate.EnvironmentMonitor.dto.common.TreeNode;
import com.smartstate.EnvironmentMonitor.entity.ObjMoudel;
import com.smartstate.EnvironmentMonitor.vo.ObjmiddleVo;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

public interface ObjMoudelService extends ServiceBase<ObjMoudel>{

    /**
     * 楼宇树结构
     * @return
     */
    List<TreeNode> selectMoudel(String type);

    /**
     * 添加图片
     * @param objMoudel
     * @return
     */
    int updatePhoto(@RequestParam(value = "file", required = false) MultipartFile file, ObjMoudel objMoudel);


    /**
     * 拿到楼宇id和计量管理
     * @param
     * @return
     */
    int updateMetering(String id,String metering);

    /**
     * 添加设备 和楼宇 中间表
     * @param objmiddleVo
     */
    int addObjmiddle(ObjmiddleVo objmiddleVo);

    boolean addOrUpdateNode(ObjMoudelDTO objMoudelDTO);

    boolean delectNode(List<String> list);
}
